package com.peas.platform.module.icims.expenditure.disbursement.adapter.repository.po;

import java.util.*;
import java.math.*;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.peas.platform.common.core.annotation.Comment;
import com.peas.platform.framework.mybatisplus.po.BasePo;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.apache.ibatis.type.JdbcType;
import javax.validation.constraints.*;

// 国库支付令
@Data
@EqualsAndHashCode(callSuper = false)
@TableName(value = "`tbl_expenditure_treasury`")
public class ExpenditureTreasuryPo extends BasePo {

    // 支付令类型
    // 枚举取值:ExpenditureTreasuryType
    @Comment(value = "支付令类型", enumType = "ExpenditureTreasuryType")
    @NotBlank(message = "支付令类型不能为空")
    @Size(max = 20, message = "支付令类型不能超过20个字符")
    @TableField(value = "`treasury_type`", jdbcType = JdbcType.VARCHAR)
    private String treasuryType;

    // 支付令编码
    // 自动生成
    @Comment(value = "支付令编码")
    @Size(max = 100, message = "支付令编码不能超过100个字符")
    @TableField(value = "`treasury_code`", jdbcType = JdbcType.VARCHAR)
    private String treasuryCode;

    // 支付令名称
    @Comment(value = "支付令名称")
    @NotBlank(message = "支付令名称不能为空")
    @Size(max = 200, message = "支付令名称不能超过200个字符")
    @TableField(value = "`treasury_name`", jdbcType = JdbcType.VARCHAR)
    private String treasuryName;

    // 申请日期
    @Comment(value = "申请日期")
    @TableField(value = "`application_date`", jdbcType = JdbcType.TIMESTAMP)
    private Date applicationDate;

    // 申请人部门ID
    // （组织架构表）外键
    @Comment(value = "申请人部门ID")
    @TableField(value = "`application_organization_id`", jdbcType = JdbcType.BIGINT)
    private Long applicationOrganizationId;

    // 申请人用户ID
    // （用户表）外键
    @Comment(value = "申请人用户ID")
    @TableField(value = "`application_user_id`", jdbcType = JdbcType.BIGINT)
    private Long applicationUserId;

    // 申请金额
    @Comment(value = "申请金额")
    @TableField(value = "`amount`", jdbcType = JdbcType.DECIMAL)
    private BigDecimal amount;

    // 状态
    // 枚举取值:ExpenditureTreasuryState
    @Comment(value = "状态", enumType = "ExpenditureTreasuryState")
    @Size(max = 20, message = "状态不能超过20个字符")
    @TableField(value = "`state`", jdbcType = JdbcType.VARCHAR)
    private String state;

    // 收款类型
    // 收款单位、公务卡
    // 枚举取值:ExpenditureReimbursementPayeeType
    @Comment(value = "收款类型", enumType = "ExpenditureReimbursementPayeeType")
    @Size(max = 20, message = "收款类型不能超过20个字符")
    @TableField(value = "`payee_type`", jdbcType = JdbcType.VARCHAR)
    private String payeeType;

    // 资金往来对象类别
    @Comment(value = "资金往来对象类别")
    @NotBlank(message = "资金往来对象类别不能为空")
    @Size(max = 20, message = "资金往来对象类别不能超过20个字符")
    @TableField(value = "`fund_dealings`", jdbcType = JdbcType.VARCHAR)
    private String fundDealings;

    // 资金类型
    @Comment(value = "资金类型")
    @Size(max = 20, message = "资金类型不能超过20个字符")
    @TableField(value = "`fund_type`", jdbcType = JdbcType.VARCHAR)
    private String fundType;

    // 单位内部机构
    // 文本输入
    @Comment(value = "单位内部机构")
    @NotBlank(message = "单位内部机构不能为空")
    @Size(max = 200, message = "单位内部机构不能超过200个字符")
    @TableField(value = "`inner_org`", jdbcType = JdbcType.VARCHAR)
    private String innerOrg;

    // 支付方式(国库)
    @Comment(value = "支付方式(国库)")
    @NotBlank(message = "支付方式(国库)不能为空")
    @Size(max = 20, message = "支付方式(国库)不能超过20个字符")
    @TableField(value = "`pay_type`", jdbcType = JdbcType.VARCHAR)
    private String payType;

    // 结算方式
    @Comment(value = "结算方式")
    @NotBlank(message = "结算方式不能为空")
    @Size(max = 20, message = "结算方式不能超过20个字符")
    @TableField(value = "`settle_type`", jdbcType = JdbcType.VARCHAR)
    private String settleType;

    // 支付业务类型
    @Comment(value = "支付业务类型")
    @NotBlank(message = "支付业务类型不能为空")
    @Size(max = 20, message = "支付业务类型不能超过20个字符")
    @TableField(value = "`business_type`", jdbcType = JdbcType.VARCHAR)
    private String businessType;

    // 国库支付令号
    @Comment(value = "国库支付令号")
    @Size(max = 300, message = "国库支付令号不能超过300个字符")
    @TableField(value = "`exchequer`", jdbcType = JdbcType.VARCHAR)
    private String exchequer;

    // 国库支付令消息
    @Comment(value = "国库支付令消息")
    @Size(max = 500, message = "国库支付令消息不能超过500个字符")
    @TableField(value = "`exchequer_message`", jdbcType = JdbcType.VARCHAR)
    private String exchequerMessage;

    // 摘要
    @Comment(value = "摘要")
    @Size(max = 1000, message = "摘要不能超过1000个字符")
    @TableField(value = "`summary`", jdbcType = JdbcType.VARCHAR)
    private String summary;

    // 备注
    @Comment(value = "备注")
    @TableField(value = "`remark`", jdbcType = JdbcType.CLOB)
    private String remark;

}
